public class FinallyTest {

  public static void main(String[] args) {
    System.out.println(function(Integer.parseInt(args[0])));
  }

  private static int function(int n) {
    try {
      return n * n;
    } finally {
      if (n == 2)
        return 0;
    }
  }

}
